<?php
session_start();
?>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>HomeStay - Home</title>
        <script type="text/javascript" src="js/jquery-1.9.1.js"></script>
        <script type="text/javascript" src="js/jquery-ui-1.10.2.custom.js"></script>
        <script type="text/javascript" src="js/jquery.lightbox-0.5.js"></script>
        <link rel="stylesheet" type="text/css" href="css/jquery.lightbox-0.5.css"/>
        <link rel="stylesheet" href="css/smoothness/jquery-ui-1.10.2.custom.css">
        <link rel="stylesheet" type="text/css" href="css/gallery.css" />
        <link type="text/css" href="bootstrap/css/bootstrap.min.css" rel="stylesheet" media="screen">
        <script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
    </head>
    <body>
        <table border="1" width="1024" cellspacing="0" cellpadding="0" align="center">
            <tr>
                <td colspan="2" width="1024" height="100">[Header]</td>
            </tr>
            <tr>
                <td colspan="2" width="1024"><a href="index.php">Home</a></td>
            </tr>
            <tr height="180">
                <td width="260" valign="top"><?php include 'login.php'; ?></td>
                <td rowspan="2" width="764" valign="top">
                    <?php
                    if (isset($_POST['btnCheckDate'])) {
                        if ($_POST['home_stay_name'] == 0) {
//                            header("refresh:2;index.php");
                            echo '<script langquage="javascript">alert("เลือกสถานที่ก่อนค่ะ");</script>';
                            echo '<script langquage="javascript">window.location="index.php"</script>';
                        } else {
                            include 'booking_room.php';
                        }
                    } else {
                        if (isset($_REQUEST['home_stay_name'])) {
                            include 'home_stay_information.php';
                        } else if (isset($_GET['save'])) {
                            include 'booking_room_confirm.php';
                        } else if (isset($_GET['booking_history'])) {
                            include 'booking_history.php';
                        } else if (isset($_GET['booking_detail'])) {
                            include 'booking_detail.php';
                        } else {
                            echo '[some information]';
                        }
                    }
                    ?>
                </td>
            </tr>
            <tr height="500">
                <td width="260" valign="top"><?php include 'datepicker.php'; ?></td>
            </tr> 
        </table>
    </body>
</html>